using System;
using System.IO;
using System.Collections.Generic;
using System.Text;

namespace MyMedia.iPod
{
	static class StringReadUtil
	{
		public static string ReadUnicodeString(BinaryReader reader, int length)
		{
			byte[] buffer = reader.ReadBytes(length);

			UnicodeEncoding encoding = new UnicodeEncoding();
			string s = encoding.GetString(buffer);

			return s;
		}

		public static string GetUnicodeString(byte[] data)
		{
			UnicodeEncoding encoding = new UnicodeEncoding();
			
			return encoding.GetString(data);
		}
	}
}
